package cn.datawin.str;

import cn.hutool.core.text.StrSplitter;

import java.util.List;

public class Demo {
    public static void main(String[] args) {
        //按照正则来切分字符串,limit<=0 不限制分片数
        List<String> list = StrSplitter.splitByRegex("192.168.2.1,192.168.2.2，，   192.168.2.3",
                "[,，]", -1, true, true);
        list.forEach(System.out::println);
    }
}
